home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 23 / CU Amiga - Super CD-ROM 23 (June 1998).iso / CUCD / Programming / OUI / include / gadgets / eslide.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  1.5 KB  |  67 lines

  1. // $Id: eslide.h 1.3 1997/07/14 04:26:54 dlorre Exp dlorre $
  2. #ifndef CLASS_ESLIDE_H
  3. #define CLASS_ESLIDE_H
  4.  
  5. #ifndef EXEC_TYPES_H
  6. #include <exec/types.h>
  7. #endif
  8.  
  9. #if !defined( PLACETEXT_LEFT )
  10. #define PLACETEXT_LEFT  0x0001  /* Right-align text on left side */
  11. #endif
  12.  
  13. #ifndef INTUITION_GADGETCLASS_H
  14. #define LORIENT_HORIZ   1
  15. #endif
  16.  
  17. #ifndef CLASS_WINDOW_H
  18. class window ;
  19. #endif
  20.  
  21. #ifndef CLASS_GADGETLIST_H
  22. class gadgetlist ;
  23. #endif
  24.  
  25. #ifndef CLASS_GADGET_H
  26. #include "gadgets/gadget.h"
  27. #endif
  28.  
  29. // ========================================================================
  30. // ============================  ESLIDE CLASS =============================
  31. // ========================================================================
  32.  
  33.  
  34. class eslide : public gadget
  35. {
  36.     long        cursel ;
  37.     long        smin ;
  38.     long        smax ;
  39.     BOOL        disabled ;
  40.     STRPTR      norm1 ;
  41.     STRPTR      norm2 ;
  42.     STRPTR      under ;
  43.  
  44.     IntuiText   *it1 ;
  45.     IntuiText   *it2 ;
  46.     IntuiText   *it3 ;
  47.  
  48.     TextFont    *font ;
  49.     TTextAttr   *underline ;
  50.     TTextAttr   *plain ;
  51. public:
  52.     eslide(gadgetlist *gl,
  53.                void (window::*func)(gadget *, unsigned long, unsigned short),
  54.                long min,
  55.                long max,
  56.                long level,
  57.                long freedom=LORIENT_HORIZ,
  58.                const char *t=NULL,
  59.                long flags=PLACETEXT_LEFT) ;
  60.     ~eslide() ;
  61.     void set(long level, long min=-1, long max=-1, short disable=FALSE) ;
  62.     void action(unsigned long classe, unsigned short code) ;
  63.     void keystroke(BOOL shifted) ;
  64. };
  65.  
  66. #endif
  67.